package com.app.config.async;

import com.app.utils.YamlPropertySourceFactory;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * async executor properties
 *
 * @author ch
 * @date 2022/12/18 01:51
 */
@Component
@PropertySource(value = {"classpath:asyncConfig.yml"}, factory = YamlPropertySourceFactory.class)
@ConfigurationProperties(prefix = "async.executor.properties")
@Data
public class AsyncExecutorProperties {

    private int corePoolSize;

    private int maxPoolSize;

    private int keepAliveSeconds;

    private int queueCapacity;
}
